package com.gzz.manage.base.customer;

import java.time.LocalDateTime;
import com.gzz.common.base.BaseCondition;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

/**
 * @类说明 【客户信息】查询条件
 * @author 高振中
 * @date 2021-03-21 11:03:35
 **/
@Setter
@Getter
//@Accessors(chain = true)
@Builder
@AllArgsConstructor
@NoArgsConstructor
@ApiModel(description = "【客户信息】查询条件")
public class CustomerCond extends BaseCondition {

	/**
	 * @方法说明: 拼加条件
	 **/
	@Override
	public void addCondition() {
		add("AND t.id = ?", id);
		add("AND t.username LIKE ?", username, 3);
		add("AND t.password LIKE ?", password, 3);
		add("AND t.wechat LIKE ?", wechat, 3);
		add("AND t.address LIKE ?", address, 3);
		add("AND t.avatar LIKE ?", avatar, 3);
		add("AND t.remark LIKE ?", remark, 3);
		add("AND t.tel LIKE ?", tel, 3);
		add("AND t.levelId = ?", levelId);
		add("AND t.createTime = ?", createTime);
		add("AND t.updateTime = ?", updateTime);
		add("AND t.id IN", ids);
	}

	// 默认条件↓
	@ApiModelProperty( value = "主键", required = true)
	private Integer id; // 主键
	@ApiModelProperty( value = "用户名", required = true)
	private String username; // 用户名
	@ApiModelProperty( value = "密码", required = true)
	private String password; // 密码
	@ApiModelProperty( value = "微信号", required = true)
	private String wechat; // 微信号
	@ApiModelProperty( value = "地址", required = true)
	private String address; // 地址
	@ApiModelProperty( value = "头像", required = true)
	private String avatar; // 头像
	@ApiModelProperty( value = "备注", required = true)
	private String remark; // 备注
	@ApiModelProperty( value = "电话号", required = true)
	private String tel; // 电话号
	@ApiModelProperty( value = "会员等级", required = true)
	private Integer levelId; // 会员等级
	@ApiModelProperty( value = "注册时间", required = true)
	private LocalDateTime createTime; // 注册时间
	@ApiModelProperty( value = "修改时间", required = true)
	private LocalDateTime updateTime; // 修改时间
	@ApiModelProperty("主键数组")
	private Object[] ids;// 主键列表
	// 自定义条件↓
}